 // 接口地址：http://jx.xuzhixiang.top/ap/api/productlist.php
        //          接口请求方式：get
        //          接口参数：
        //               无需参数（不登录也能看到商品列表）
        //                uid 可选参数，可以看到当前用户上传到服务器的商品
        //          使用方式
        //     http://jx.xuzhixiang.top/ap/api/productlist.php

        let middleshop = document.querySelector(".rein");
        let middleshop2 = document.querySelector("#rein2");
        let middleshop3 = document.querySelector("#rein3");
        // let middleshop4 = document.querySelector("#shop-4");
        // let middleshop5 = document.querySelector("#shop-5");
        // let middleshop6 = document.querySelector("#shop-6");

        window.onload = function () {
            let shopapi = "http://jx.xuzhixiang.top/ap/api/productlist.php"
            let uid = localStorage.getItem("id");
            console.log(uid);
            axios.get(shopapi, {
                    params: {
                        uid
                    }
                })
                .then((r) => {
                    let rr = r.data.data;
                    console.log(rr);
                    let ahtml = rr.map((v) =>
                        ` <ul class="region">
                            <a href="commodity.html?id=${v.pid}">
                            <img src="${v.pimg}"
                                    alt="">
                                <p class="price"><span>￥</span>${v.pdesc}</p>
                                <p class="prica"><a href="">${v.pname}</a></p>
                            </a>
                        </ul> `
                    ).join("")


                    middleshop.innerHTML = ahtml
                    middleshop2.innerHTML = ahtml
                    middleshop3.innerHTML = ahtml
                    // middleshop4.innerHTML = ahtml
                    // middleshop5.innerHTML = ahtml
                    // middleshop6.innerHTML = ahtml

                })
        }